﻿<UserControl x:Class="Lights.Page.LibraryPage"
             xmlns="http://schemas.microsoft.com/winfx/2006/xaml/presentation"
             xmlns:x="http://schemas.microsoft.com/winfx/2006/xaml"
             xmlns:mc="http://schemas.openxmlformats.org/markup-compatibility/2006" 
             xmlns:d="http://schemas.microsoft.com/expression/blend/2008" 
             xmlns:xcad="http://schemas.xceed.com/wpf/xaml/avalondock"
             xmlns:xctk="http://schemas.xceed.com/wpf/xaml/toolkit"
             xmlns:local="clr-namespace:Lights.Controls"
             Name="libraryPage"
             mc:Ignorable="d" 
             d:DesignHeight="300" d:DesignWidth="600"
             Loaded="UserControl_Loaded"
             FontSize="12"
             >
    <Grid>
        <Grid.ColumnDefinitions>
            <ColumnDefinition Width="120"/>
            <ColumnDefinition Width="34*"/>
            <ColumnDefinition Width="120"/>
        </Grid.ColumnDefinitions>
        <Grid.RowDefinitions>
            <RowDefinition Height="118*"/>
            <RowDefinition Height="30"/>
        </Grid.RowDefinitions>
        <Expander Header="Raccolte" Margin="3" Background="WhiteSmoke" IsExpanded="True" >
            <ListBox Name="lbCollections" ItemsSource="{Binding ElementName=libraryPage,Path=Collections}" >
                <ListBox.ItemTemplate>
                    <DataTemplate>
                        <TextBlock Text="{Binding Name}" />
                    </DataTemplate>
                </ListBox.ItemTemplate>
            </ListBox>
        </Expander>
        <local:CollectionViewer x:Name="viewer" Grid.Column="1" Grid.RowSpan="2" ItemsSource="{Binding ElementName=libraryPage,Path=AllPhotos}" />
        <StackPanel Grid.Column="2">
            <Expander Header="Cerca" >
                <StackPanel Margin="3">
                    <TextBlock Text="Cerca:"/>
                    <TextBox Name="txtSearch" />
                </StackPanel>
            </Expander>
            <Expander Header="Filtra" >
                <ListBox Name="lstFilters">
                    <ListBoxItem Content="Data" />
                </ListBox>
            </Expander>
        </StackPanel>
        <Button Content="Importa" Name="cmdImport" Margin="3" Click="cmdImport_Click" Grid.Row="1" />
    </Grid>
</UserControl>
